//
//  OKSickChooseBtn.m
//  ZLFastDoctor
//
//  Created by answer on 16/5/26.
//  Copyright © 2016年 LS. All rights reserved.
//

#import "OKSickChooseBtn.h"
#import <Masonry/Masonry.h>

@interface OKSickChooseBtn ()

@end
@implementation OKSickChooseBtn

- (instancetype)initWithFrame:(CGRect)frame {
    if (self = [super initWithFrame:frame]) {
        [self setupUI];
    }
    return self;
}

- (void)setupUI {
    
    [self addSubview:self.iconView];
    [self addSubview:self.nameLabel];
    
    [self.iconView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.centerX.equalTo(self);
        make.centerY.equalTo(self).offset(-10);
    }];
    
    [self.nameLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.centerX.equalTo(self);
        make.top.equalTo(self.iconView.mas_bottom).offset(8);
    }];
}

- (UIImageView *)iconView {
    if (_iconView == nil) {
        _iconView = [[UIImageView alloc] init];
       // [_iconView setImage:[UIImage imageNamed:@"1"]];
    }
    return _iconView;
}

- (UILabel *)nameLabel {
    if (_nameLabel == nil) {
        _nameLabel = [[UILabel alloc] init];
        //_nameLabel.text = @"肿瘤";
    }
    return _nameLabel;
}

@end







